<?php
/**
 * ExtMenuPanel class file
 *
 * @author TrueSoftware B.V. (The Netherlands)
 * @link http://www.ext4yii.com
 * @copyright Copyright 2007-2010 TrueSoftware B.V. all rights reserved.
 * @license http://www.ext4yii.com/license/
 *          EVALUATION VERSION - NOT FOR COMMERCIAL USE OR DISTRIBUTION.
 * @version 0.7.2
 */

class ExtMenuPanel extends ExtMenuPanelBase
{
    /**
     * Gets the value of ExtJS selectedIndex property
     * @return Number 
     */
    public function getSelectedIndex()
    {
    	return $this->getConfig("selectedindex");
    }

    /**
     * Sets the value of ExtJS selectedIndex property
     * @param Number $value 
     */
    public function setSelectedIndex($value)
    {
    	$this->setConfig("selectedindex",$value);
    }

    /**
     * Gets the value of ExtJS trackSelection property
     * @return Boolean 
     */
    public function getTrackSelection()
    {
    	return $this->getConfig("trackselection");
    }

    /**
     * Sets the value of ExtJS trackSelection property
     * @param Boolean $value 
     */
    public function setTrackSelection($value)
    {
    	$this->setConfig("trackselection",$value);
    }

    /**
     * @description maps to the setSelectedIndex function in Ext.ux.MenuPanel
     * @param sender String -
     * @param menu (Number) - 
     */
    public static function setSelectedIndex_OnAjax($menu,$sender=null)
    {
    	ExtWidget::checkSetAjaxRequestValue('setSelectedIndex(%s)',
    		array($menu),
    			 $sender);
    }

    
    public function __construct()
    {
        parent::__construct();
        $this->configmap = array_merge($this->configmap,array(
            'selectedindex' => 'selectedIndex',
            'trackselection' => 'trackSelection'
        ));



        $this->proptags = array_merge($this->proptags,array(
            'menu' => true
        ));
        $this->setXType('menupanel');
        $this->setXClass('Ext.ux.MenuPanel');
    }    
}
?>